package com.smart.campus.controller;

import com.smart.campus.dto.ShCheck;
import com.smart.campus.interfaces.ShCheckServiceApi;
import com.smart.campus.pojo.PagedResponse;
import com.smart.campus.service.ShCheckService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @BelongsProject: smart-campus
 * @BelongsPackage: com.smart.campus.controller
 * @Author: 戴冰洁
 * @CreateTime: 2024-10-08  14:04
 * @Description: TODO
 * @Version: 1.0
 */
@RestController
public class ShCheckController implements ShCheckServiceApi {
    @Autowired
    private ShCheckService shCheckService;

    @Override
    public List<ShCheck> findshcheck() {
        return shCheckService.findshcheck();
    }

    @Override
    public void addshcheck(ShCheck shCheck) {
        shCheckService.addshcheck(shCheck);
    }

    @Override
    public void deleteshcheck(Integer id) {
        shCheckService.deletebyid(id);
    }

    @Override
    public ShCheck shcheckList(Integer id) {
        return shCheckService.shcheckList(id);
    }

    @Override
    public void updateshcheck(ShCheck shCheck) {
        shCheckService.updateshcheck(shCheck);
    }

    @Override
    public PagedResponse<ShCheck> pageShChenck(ShCheck shCheck, Integer pageNUm, Integer pageSize) {
        return shCheckService.pageShChenck(shCheck,pageNUm,pageSize);
    }
}
